package alp.starcode.nudtportal.framework.mybatis.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.io.Serializable;
import java.math.BigDecimal;

/**
 * <p>
 * user_transaction_stream（用户交易流水表）
 * </p>
 *
 * @author xwx
 * @since 2023-08-08
 */
@Data
@EqualsAndHashCode(callSuper = false)
@TableName("user_transaction_stream")
@ApiModel(value = "UserTransactionStream对象", description = "user_transaction_stream（用户交易流水表）")
public class UserTransactionStream extends Model<UserTransactionStream> {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "交易流水号")
    @TableId("transaction_id")
    private String transactionId;

    @ApiModelProperty(value = "用户流水号")
    @TableField("user_id")
    private String userId;

    @ApiModelProperty(value = "交易时间")
    @TableField("transaction_time")
    private Long transactionTime;

    @ApiModelProperty(value = "交易类型：0充值、1消费、2补助")
    @TableField("transaction_type")
    private Integer transactionType;

    @ApiModelProperty(value = "交易金额")
    @TableField("transaction_money")
    private BigDecimal transactionMoney;

    @ApiModelProperty(value = "交易状态")
    @TableField("transaction_status")
    private String transactionStatus;

    @ApiModelProperty(value = "创建时间")
    @TableField("create_time")
    private Long createTime;

    @ApiModelProperty(value = "钱包类型(0-现金钱包，1-补助钱包)")
    @TableField("wallet_type")
    private Integer walletType;

    @ApiModelProperty(value = "修改时间")
    @TableField("update_time")
    private Long updateTime;


    @Override
    protected Serializable pkVal() {
        return this.transactionId;
    }

}
